<%@ page language="java" contentType="text/html; charset=utf-8" pageEncoding="utf-8" isELIgnored="false" %>
<%
    String path = request.getContextPath();
    String basePath = request.getScheme() + "://"+ request.getServerName() + ":" + request.getServerPort()+ path + "/";
%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
<%@ taglib prefix="fn" uri="http://java.sun.com/jsp/jstl/functions"%> 
<%@taglib uri="http://java.sun.com/jsp/jstl/fmt" prefix="fmt"%>
<script src="<%=basePath%>resources/js/common/plugin/bootstrap/js/bootstrap-validation.js"></script>


<title>新增平台信息</title>

<style type="text/css"> 
.modal-table{width:100%;}
.modal-table tr{line-height:35px;}
/* .modal-table th{width:11%;text-align:right;padding-right:10px;font-weight: normal;}
.modal-table td{width:44%;} */
.modal-table th{width:20%;text-align:right;padding-right:10px;font-weight: normal;}
.modal-table td{width:30%;}
.date-alarm-ul {
    border: 1px solid #dedede;
}
.fl {
    float: left;
}
input{
border: 1px solid #dedede;
padding-left:10px;
}
#inputStartDate,#inputEndDate{
	width:180px;
	height:24px;
	padding-left:30px;
	}
.modal-body{
	padding:0;
}
/* .alertaddup {cursor:pointer; position:absolute; left:180px; top:0;} */
#baseInfoDiv .placeholder::-webkit-input-placeholder {
     color: #444 !important;
}       
#baseInfoDiv .placeholder:focus::-webkit-input-placeholder {
	color: #444 !important;
}      
#baseInfoDiv .placeholder:-moz-placeholder {
     color: #444 !important;
}     
#baseInfoDiv .placeholder:focus:-moz-placeholder {
     color: #444 !important;
}        
#baseInfoDiv .placeholder::-moz-placeholder {
     color:#444 !important;
}       
#baseInfoDiv .placeholder:focus::-moz-placeholder {
     color: #444 !important;
}       
#baseInfoDiv .placeholder:-ms-input-placeholder {
     color: #444 !important;
}        
#baseInfoDiv .placeholder:focus:-ms-input-placeholder {
	 color: #444 !important;
}

</style> 
<script type="text/javascript">
var platformId = '${platformId}';
var action = '${action}';
</script>
</head>
<body>
<form id="platformForm">
			<input type="hidden" id="action" name="action" value="${action}"/>
			<input type="hidden" name="platform_type" id="platform_type" value="${platform.platformType}"/>
			<input type="hidden" name="platformId" id="platformId" value="${platform.platformId}"/>			
			<div id="baseInfoDiv" class="pr">
			<table class="modal-table">
 				<tr>
					<th>平台名称：</th>
					<td>
						<input type="text" class='placeholder' style="height: 24px;width:208px;" name="platformName" id="platformName" value="${platform.platformName}" 
						placeholder="名称长度3-30"/>
						<span id="namemsg"><font style="color:#f00;"> *</font></span>
					</td>
					<th>所属单位：</th>
					<td>
						<input type="text"  style="height: 24px;width:208px;" id="owner_unit" name="owner_unit"  
						value="${platform.owner_unit}"/>
					</td>
				</tr>
				<tr>
					<th>平台简称：</th>
					<td>
						<input type="text" class='placeholder' style="height: 24px;width:208px;" name="short_name" id="short_name" placeholder="简称2-10位" 
						value="${platform.short_name}"/><font style="color:#f00;"> *</font>
					</td>
					<th>平台类型：</th>
					<td >
						<div id = "queryByPlatformType">
						 <select class="userInput fl" style="height: 24px;width:207px;" name="platformType" id="platformType"  ></select> 
						</div>
					</td>
				</tr>
				<tr>
					<th>唯一编码：</th>
					<td>
						<input type="text" class='placeholder' style="height: 24px;width:208px;" name="platformUniCode" id="platformUniCode" placeholder="3-12数字"
						value="${platform.platformUniCode}"/>
						<span id = "namemsg"></span><font style="color:#f00;"> *</font></span>
					</td>
					<th>平台接入码：</th>
					<td>
						<input type="text" class='placeholder' style="height: 24px;width:208px;" id="accessCenterCode" name="accessCenterCode" placeholder="3-10数字" 
						value="${platform.accessCenterCode}"/>
						<font style="color:#f00;"> *</font>
					</td>
				</tr>
				<tr>
					<th>联系号码：</th>
					<td>
						<input type="text"  style="height: 24px;width:208px;" id="contactNumber" name="contactNumber" placeholder="" 
						value="${platform.contactNumber}"/>
					</td>
					<th>短息提醒：</th>
					<td>
						<select style="height: 24px;width:208px;padding-left:7px;" id="enable_sms" name="enable_sms">
							<option value="1" ${platform.enable_sms == "1"?"selected='selected'":""}>启用</option>
							<option value="0" ${platform.enable_sms == "0"?"selected='selected'":""}>停用</option>
						</select>
					</td>
				</tr>
				<tr>
					<th>联系邮箱：</th>
					<td>
						<input type="text" style="height: 24px;width:208px;" name="email" id="email" value="${platform.email}"/>
					</td>
					<th>邮件提醒：</th>
					<td>
						<select style="height: 24px;width:208px;padding-left:7px;" id="enable_email" name="enable_email" >
							<option value="1" ${platform.enable_email == "1"?"selected='selected'":""}>启用</option>
							<option value="0" ${platform.enable_email == "0"?"selected='selected'":""}>停用</option>
						</select>
					</td>
				</tr>
				<tr>
					<th>联系人：</th>
					<td>
						<input type="text" style="height: 24px;width:208px;" name="contact" id="contact" placeholder="" 
						value="${platform.contact}"/>
					</td>
					<th>用户ID：</th>
					<td>
						<input type="text" class='placeholder' style="height: 24px;width:208px;" name="userId" id="userId" placeholder="3-10位数字" 
						value="${platform.userId}"/>
						<font style="color:#f00;"> *</font>
					</td>
				</tr>
				<c:if test="${action == 'insert'}">
					<tr>
						<th>密码：</th>
						<td>
							<input type="password" class='placeholder' style="height: 24px;width:208px;" name="passWord" id="passWord" placeholder="长度3-8"
							value="${platform.passWord}"/>	
							<font style="color:#f00;"> *</font>
						</td>
						<th>确认密码：</th>
						<td>
							<input type="password" class='placeholder'  style="height: 24px;width:208px;" id="passWordConfirm" name="passWordConfirm" placeholder="确认密码 " />
							<font style="color:#f00;">*</font>
						</td>
					</tr>
				</c:if>
				<tr>
					<th>链路IP：</th>
					<td>
						<input type="text" class='placeholder' style="height: 24px;width:208px;" name="subIP" id="subIP" placeholder="IP地址" 
						value="${platform.subIP}"/>
						<font style="color:#f00;"> *</font>
					</td>
					<th>链路端口：</th>
					<td>
						<input type="text" class='placeholder'  style="height: 24px;width:208px;" id="subPort" name="subPort" placeholder="端口号最多5位"
						value="${platform.subPort}"/>
						<font style="color:#f00;"> *</font>
					</td>
				</tr>
				
				<tr>
					<th>C1：</th>
					<td>
						<input type="text" style="height: 24px;width:208px;" name="IC1" id="IC1" 
						value="${platform.IC1}"/>
					</td>
					<th>M1：</th>
					<td>
						<input type="text" style="height: 24px;width:208px;" name="M1" id="M1" value="${getM1}"
						value=""/>
					</td>
				</tr>
				<tr>
					<th>软件开发单位：</th>
					<td>
						<input type="text"  style="height: 24px;width:208px;" id="softWareUnit" name="softWareUnit" 
						value="${platform.softWareUnit}" />
					</td>
					<th>A1：</th>
					<td>
						<input type="text" style="height: 24px;width:208px;" name="IA1" id="IA1" 
						value="${platform.IA1}"/>
					</td>
				</tr>
				<tr>
					<th>技术支持单位：</th>
					<td>
						<input type="text" style="height: 24px;width:208px;" name="techSupportUnit" id="techSupportUnit" 
						value="${platform.techSupportUnit}"/>
					</td>
					<th>备注：</th>
					<td><!-- //colspan="3" -->
						<textarea rows="1" cols="20" type="text" style="height: 24px;width:208px;padding-left:5px;margin-top:3px;border-style:none;border:1px solid #dedede" name="memo" id="memo" 
						 >${platform.memo}</textarea>
					</td>
				</tr>
				
			</table>
			</div>
		</form>
	
		<script src="<%=basePath%>resources/js/business/base/platform/addPlatformForm.js"></script>
</body>
</html>